package connect;

import org.apache.mina.core.session.IoSession;
import org.apache.mina.filter.codec.ProtocolCodecFactory;
import org.apache.mina.filter.codec.ProtocolDecoder;
import org.apache.mina.filter.codec.ProtocolEncoder;

public class CodecFactory implements ProtocolCodecFactory
{
	public static final MyDeCoder decoder = new MyDeCoder();
	
	public static final MyEnCoder encoder = new MyEnCoder();

    public ProtocolDecoder getDecoder(IoSession arg0) throws Exception
    {
	    return decoder;
    }

    public ProtocolEncoder getEncoder(IoSession arg0) throws Exception
    {
	    return encoder;
    }

}
